const originObject = {
  name: "John",
  age: 30,
  address: {
    city: "New York",
    country: "USA",
  },
};

const deepCopy = structuredClone(originObject);
deepCopy.name = "Jane";
deepCopy.address.city = "Los Angeles";

/**
{
  name: 'Jane',
  age: 30,
  address: { city: 'Los Angeles', country: 'USA' }
}
 */
console.info(deepCopy); 